﻿<Window x:Class="Freshome.m.MainWindow" Title="{Binding Name}"
        xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
        xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
        xmlns:m="clr-namespace:Freshome.m.vms"
        xmlns:v="clr-namespace:Freshome.m.vws"
        Style="{StaticResource biggish}"
        Icon="/Freshome.m;component/Favicon.ico" Loaded="Window_Loaded" WindowStartupLocation="CenterScreen">
    <Grid>
        <Grid.RowDefinitions>
            <RowDefinition Height="Auto"/>
            <RowDefinition />
            <RowDefinition Height="Auto"/>
        </Grid.RowDefinitions>
        <Grid.ColumnDefinitions>
            <ColumnDefinition />
            <ColumnDefinition Width="Auto"/>
        </Grid.ColumnDefinitions>
        <TabControl x:Name="taboard" ItemsSource="{Binding Workspaces}" Grid.ColumnSpan="2" Grid.RowSpan="2" Margin="2" IsSynchronizedWithCurrentItem="True">
        </TabControl>
        <Menu HorizontalAlignment="Right" Grid.Column="1" Padding="2" Margin="2">
            <MenuItem Header="材料(_M)">
                <MenuItem Header="{Binding Path=MajorawCmd.Name}" Command="{Binding Path=MajorawCmd}"/>
                <MenuItem Header="{Binding Path=MinorawCmd.Name}" Command="{Binding Path=MinorawCmd}"/>
                <MenuItem Header="{Binding Path=HealthCmd.Name}" Command="{Binding Path=HealthCmd}"/>
            </MenuItem>
            <MenuItem Header="菜谱(_R)">
                <MenuItem Header="{Binding Path=ColdishCmd.Name}" Command="{Binding Path=ColdishCmd}"/>
                <MenuItem Header="{Binding Path=DishotCmd.Name}" Command="{Binding Path=DishotCmd}"/>
                <MenuItem Header="{Binding Path=SoupotCmd.Name}" Command="{Binding Path=SoupotCmd}"/>
                <MenuItem Header="{Binding Path=SnackCmd.Name}" Command="{Binding Path=SnackCmd}"/>
                <MenuItem Header="{Binding Path=PastryCmd.Name}" Command="{Binding Path=PastryCmd}"/>
                <MenuItem Header="{Binding Path=DrinkCmd.Name}" Command="{Binding Path=DrinkCmd}"/>
            </MenuItem>
            <MenuItem Header="帮助(_H)">
                <MenuItem Header="关于(_A)..." Name="helpAbout" Click="helpAbout_Click" />
            </MenuItem>
        </Menu>
        <StatusBar Grid.Row="2" Background="Beige">
            <StatusBarItem>
                <TextBlock Text="{Binding Path=Leftext}"></TextBlock>
            </StatusBarItem>
        </StatusBar>
        <TextBlock Grid.Row="2" Grid.Column="1" Text="{Binding Path=Rightext}"></TextBlock>
    </Grid>
</Window>
